# md5=hashlib.md5
# md5.update(str(time.clock()).encode('utf-8'))
# md5.update(json_response['session_key'].encode('utf-8'))
# token = md5.hexdigest()

'''
{  # for (let i = 1; i < col; i++) {#}
    {  # let html = '<div id="col-' + i + '"></div>';#}
        {  # $('#p2').append(html);#}
            {  # for (let j = 1; j < row; j++) {#}
                {  # let coord = i + "-" + j;#}
                    {  # console.log(coord)#}
                        {
                            # let html = '<button style=\'width:' + 100 / (col-1  ) + '%;height:110px;background-color: cornsilk\'>\n' +#}
                            {  # '                    <div class="caption">\n' +#}
                                {
                                    # '                        <img src="/static/img/devices.png" alt="" id=row-' + coord + ' style=\'width:100%;height:80px\'>\n' +#}
                                    {  # '                        <p>座位:' + coord + '</p>\n' +#}
                                        {  # '                    </div>\n' +#}
                                            {  # '                </button>';#}
                                                {  # $('#col-' + i).append(html)#}
                                                    {  # }#}
                                                        {  # }#}'''


#首页代码
'''
后台
def test(request):
    # kaoqin_obj = models.KaoQin.objects.all()
    # # stu_obj=models.StudentInfo.objects.filter(snum='1840226103')
    # classname = 't201'
    # res=models.ClassInfo.objects.filter(classroomnum=classname).values('rowcolumn','rowline').first()
    # row=int(res['rowline'])
    # col=int(res['rowcolumn'])
    # list1=[]
    # for i in range(1,row):
    #     for j in range(1,col):
    #         list1.append('{}-{}'.format(i,j))
    # return render(request,'test.html',locals())
前端
{#{% load static %}#}
{#<div class="panel panel-info">#}
{#    <a href="">#}
{#        <div class="col-md-11">#}
{#            {% for re in list1 %}#}
{#                <button style='width:120px;height:110px;margin:5px 5px;background-color: cornsilk'>#}
{#                    <div class="caption">#}
{#                        <img src="{% static 'img/devices.png' %}" alt="" id="{{ re }}" style='width:110px;height:80px'>#}
{#                        <p>当前座位:{{ re|safe }}</p>#}
{#                    </div>#}
{#                </button>&nbsp;&nbsp;#}
{#            {% endfor %}#}
{#            <script>#}
{#                {% for re1 in kaoqin_obj %}#}
{#                    $('#{{re1.seatcoordinates}}').attr("src", "{{re1.avatar}}");#}
{#                {% endfor %}#}
{#            </script>#}
{#        </div>#}
{#    </a>#}
{#</div>#}
'''
'''
index.html底部代码
<!-- Bootstrap core JavaScript
================================================== -->
<!-- Placed at the end of the document so the pages load faster -->
{#    <script src="https://code.jquery.com/jquery-1.12.4.min.js" integrity="sha384-nvAa0+6Qg9clwYCGGPpDQLVpLNn0fRaROjHqs13t4Ggj3Ez50XnGQqc/r8MhnRDZ" crossorigin="anonymous"></script>#}
{#    <script>window.jQuery || document.write('<script src="{% static 'js/jquery.min.js' %}"><\/script>')</script>#}
{#    <script src="../../dist/js/bootstrap.min.js"></script>#}
<!-- Just to make our placeholder images work. Don't actually copy the next line! -->
{#    <script src="{% static 'js/holder.min.js' %}"></script>#}
<!-- IE10 viewport hack for Surface/desktop Windows 8 bug -->
{#    <script src="../../assets/js/ie10-viewport-bug-workaround.js"></script>#}
{#    <script src="https://cdn.bootcdn.net/ajax/libs/jquery/3.4.1/jquery.min.js"></script>#}
{#    <script src="https://cdn.bootcdn.net/ajax/libs/bootstrap-sweetalert/1.0.1/sweetalert.min.js"></script>#}
{#    <link href="https://cdn.bootcdn.net/ajax/libs/bootstrap-sweetalert/1.0.1/sweetalert.min.css" rel="stylesheet">#}
'''